# Edit the lines below to point to any needed include and link paths
# Or to change the compiler's optimization flags
CC = g++
LD = g++
CFLAGS = -g -O3 -I../gltools
LFLAGS = -framework OpenGL -framework GLUT

COMMON_OBJECTS = shader.o framebuffer.o

all: $(COMMON_OBJECTS)
# compile the files
	$(CC) $(CFLAGS) -c deferredShading.cpp -o deferredShading.o
	
# link them
	$(LD) $(LFLAGS) deferredShading.o $(COMMON_OBJECTS) -o deferredShading


shader.o ../gltools/Shader.h ../gltools/Shader.cpp:
	$(CC) $(CFLAGS) -c ../gltools/Shader.cpp -o ./shader.o

framebuffer.o ../gltools/Framebuffer.h ../gltools/Framebuffer.cpp:
	$(CC) $(CFLAGS) -c ../gltools/Framebuffer.cpp -o ./framebuffer.o

clean:
	rm *.o;
	rm deferredShading;
